package aps.module_Core;

//Vanilla minecraft
import java.util.List;

import net.minecraft.src.CreativeTabs;
import net.minecraft.src.Item;
import net.minecraft.src.ItemStack;

//APS
import aps.BuildcraftAPS;

public class ItemAPSPowerCore extends Item
{
	public ItemAPSPowerCore(int i) {
		super(i);

        setHasSubtypes(true);
        setMaxDamage(0);	
        
        this.setCreativeTab(CreativeTabs.tabRedstone);
	}

	@Override
	public int getIconFromDamage(int i)
	{
		if (i < 4)
			return 17 + i;
		else
			return 16;
	}

	@Override
	public String getItemNameIS(ItemStack itemstack) {
		switch (itemstack.getItemDamage()) {
		case 0:
			return "redstonepowercore";
		case 1:
			return "ironpowercore";
		case 2:
			return "goldpowercore";
		case 3:
			return "diamondpowercore";
		default:
			return "powercore";
		}
	}

	@Override
	public String getTextureFile()
	{
		return BuildcraftAPS.imageFilesRoot + "APSItemTexes.png";
	}
	
	public void getSubItems(int par1, CreativeTabs par2CreativeTabs, List par3List)
    {
        for (int var4 = 0; var4 <= 3; ++var4)
        {
            par3List.add(new ItemStack(par1, 1, var4));
        }
    }
}